/**
 * 
 */
package truerefactor.refactor;

import java.util.List;

import truerefactor.graph.ClassNode;
import truerefactor.graph.CodeGraph;
import truerefactor.graph.CodeNode;

/**
 * @author Isaac
 */
public class ExtractSubClass extends Refactoring {

    public ExtractSubClass()
    {
        this.shortName = "EXSUBCL";
        this.name = "Extract SubClass";
        this.description = "";
    }

    /*
     * (non-Javadoc)
     * @see
     * truerefactor.refactor.Refactoring#execute(truerefactor.graph.CodeGraph
     * )
     */
    @Override
    public void execute(CodeGraph graph)
    {
        // 1. Define a new subclass of the source class

        // 2. Provide constructors for the new subclass

        // 3. Found all calls to constructors of the superclass. If they need
        // the subclass replace with a call to the new constructor.

        // 4. One by one use Push Down Method and Push Down Field to move
        // features onto the subclass

        // 5. Look for any field that designates information now indicated by
        // the hierarchy (usually a boolean or type code). Eliminate it by using
        // Self Encapsulate Field and replacing the getter with polymorphic
        // constant methods. All users of this field should be refactored with
        // Replace Conditional with Polymorphism

        // 6. Compile and test after each push down

    }
}
